prefix=@prefix@
all:
	cd unikey; make
	cd fonts; make
	cd unicon; make
	cd tools; make
	cd unimap; make

data: 
	cd unicon; make data
data-install:
	if [ ! -d $(prefix)/lib/unicon ] ; then mkdir -p $(prefix)/lib/unicon; fi
	if [ ! -d $(prefix)/bin ] ; then mkdir -p $(prefix)/bin; fi
	cd unicon; make data-install

install: all
	if [ ! -d $(prefix)/lib/unicon ] ; then mkdir -p $(prefix)/lib/unicon; fi
	if [ ! -d $(prefix)/bin ] ; then mkdir -p $(prefix)/bin; fi
	cd unicon; make install
	cd unikey; make install
	cd fonts; make install
	cd tools; make install
	cd unimap; make install

clean:
	cd unicon; make clean
	cd unikey; make clean
	cd fonts; make clean
	cd tools; make clean
	cd unimap; make clean
	rm -f core *.bak *~

distclean: clean
	rm -f config.status config.log config.cache Makefile
	cd unicon; make distclean
	cd unikey; make distclean
	cd fonts; make distclean
	cd tools; make distclean
	cd sfonts; make distclean
	cd unimap; make distclean
	rm -f *.bak

